<template>
  <div class="IV-II-I">
    <table class="IV-II-I__table">
      <tr class="IV-II-I__table-trone">
        <td class="IV-II-I__table-trone-td"
            colspan="9">
          <div class="IV-II-I__table-trone-td-title">
            IV-2学科简介（限1000字）
            <br>
            <span class="IV-II-I__table-trone-td-title-tips">
              简述学科基本情况、学科方向与优势特色、人才培养目标、生源情况、国内外影响等。
            </span>
          </div>
        </td>
      </tr>
      <tr class="IV-II-I__table-trtwo">
        <td class="IV-II-I__table-trtwo-td"
            colspan="7">
          <el-input v-model="dba.disciplineIntro"
                    class="IV-II-I__table-trtwo-td-textarea"
                    :autosize="{ minRow:10 }"
                    maxlength="1000"
                    placeholder="请输入学科简介"
                    showWordLimit
                    type="textarea"/>
        </td>
      </tr>
    </table>
  </div>
</template>

<script>
import { getPageData } from '@/utils/getData.js'

export default {
  watch: {
    dba: {
      handler (newVal) {
        sessionStorage['this_data'] = JSON.stringify(newVal)
      },
      deep: true,
      immediate: true
    }
  },
  async mounted () {
    const loading = this.$loading({ lock: true, text: '数据获取中...请稍后！', background: 'rgba(0, 0, 0, 0.7)' })
    this.dba = await getPageData('dba')
    loading.close()
  },
  data () {
    return {
      dba: {
        disciplineIntro: ''
      }
    }
  }
}
</script>

<style lang="less" scoped>
@import '../../assets/css/page/4-2-1.less';
</style>
